﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data.SqlClient;
using System.Data;

namespace BussinessLayer
{
    public class tblThamso_hoatdong
    {
        DataLayer.Data odata = new DataLayer.Data();
        public DataTable Select()
        {
            return odata.view_text("SELECT * FROM thamso_hoatdong WHERE thamso_id=(select max(thamso_id) from thamso_hoatdong) ORDER BY hoatdong");
        }
        public void thamso_hoatdong(int c1, int t1, int c2, int t2)
        {
            SqlParameter[] sp = new SqlParameter[4];
            sp[0] = new SqlParameter("@c1", c1);
            sp[1] = new SqlParameter("@t1", t1);
            sp[2] = new SqlParameter("@c2", c2);
            sp[3] = new SqlParameter("@t2", t2);
            odata.proc_TS("tblThamso_hoatdong", sp);
        }
    }
}
